package com.tanhua.dubbo.server.api;

import com.tanhua.dubbo.server.pojo.Comment;
import com.tanhua.dubbo.server.pojo.Publish;
import com.tanhua.dubbo.server.vo.CommentType;
import com.tanhua.dubbo.server.vo.IdType;
import com.tanhua.dubbo.server.vo.PageInfo;

import java.util.List;

public interface QuanZiApi {

    PageInfo<Publish> friendQuanZiPublish(Long userId, Integer page, Integer pageSize);

    PageInfo<Publish> recommendedQuanZiPublish(Long userId, Integer page, Integer pageSize);

    String savePublish(Long userId, Publish publish);

    boolean likeAndLove(Long userId, String publishId, CommentType like, String content, IdType type);

    Long likeAndLoveCount(Long userId,String publishId, CommentType like);

    Boolean saveLikeAndLoveAndComment(Long userId, String publishId, CommentType like, String content,IdType type);

    boolean judgeUserLikeAndLove(Long userId, String publishId, CommentType like);

    boolean cancelLikeAndLove(Long userId, String publishId, CommentType like, String content,IdType type);

    Publish getOnePublish(String publishId);

    List<Comment> findAllComments(Integer page, Integer pageSize,String publishId);

    PageInfo<Publish> meQuanZiPublish(Long userId, Integer page, Integer pageSize);

    /**
     * 获取评论的消息列表的数据
     * @param page
     * @param pageSize
     * @param like
     * @param userId
     * @return
     */
    List<Comment> messagesAllComment(Integer page, Integer pageSize, CommentType like, Long userId);
}
